<?php
error_reporting(0);
require_once("includes/pagetop.php");

if(!isset($_SESSION['Allyfolio_User_ID']) || $_SESSION['Allyfolio_User_ID']==0)
{
    redirect("index.php");
}

$patharr=explode("/",$_SERVER["REQUEST_URI"]);

$lastvars=end($patharr);

$afterWampToProjectRootPath=str_replace($lastvars,"",$_SERVER["REQUEST_URI"]);
if(!(isset($_REQUEST['t']) && trim($_REQUEST['t'])!=''))
{
    redirect("home.php");
}

$dnauserqry="select * from af_users where Allyfolio_User_ID=:afuserid  ";
$condition[":afuserid"]=$_REQUEST['t'];
$dnauserinfo=$pdodbobj->fetch_array($pdodbobj->query($dnauserqry,$condition));

if(count($dnauserinfo)==0)
{
    redirect($_SERVER["HTTP_REFERER"]);
}

if($dnauserinfo[0]["DOB"]!="" && $dnauserinfo[0]["DOB"]!=0)
{
	$dob=$dnauserinfo[0]["DOB"];
}
else
{
	$dob="";
}


$qryCountry="select * from af_countries order by Country_Name asc";
$arrCountry=$pdodbobj->fetch_array($pdodbobj->query($qryCountry,array()));

//echo "<pre>";
//print_r($arrCountry);
//echo "</pre>";

?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml">

<head>

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<meta http-equiv="X-UA-Compatible" content="IE=edge" />

<title>AllyFolio | DNA </title>

<link href="css/style.css" rel="stylesheet" type="text/css" media="all"  />

<link rel="stylesheet" href="alertify/themes/alertify.core.css" />
<link rel="stylesheet" href="alertify/themes/alertify.default.css" id="toggleCSS" />
<script src="alertify/lib/alertify.min.js"></script>	
<script src="js/jquery1.10.2.min.js"></script>
<script src="js/modernizr.custom.56223.js"></script>



<script src="js/jquery.placeholder.js"></script>

<style type="text/css">

	.logo{ margin-top:10px;}

	.log_button{

	

	height:auto;

	margin:6px 0;

	overflow:hidden;

	float:left;

	margin-top:10px;

	

	}

	.new tr td{ vertical-align:top}

	

	textarea select{ border:1px solid #ccc}

	input textarea select{ border:1px solid #999}

	

</style>

</head>



<body>



	<div id="main_wrapper">

    <!--=================Header Start=======================-->

	<div class="wrapper row1">
    
    <?php
    require_once("includes/dnaheader.php");
    
    ?>

    <div class="clearfix"></div>  

    </div>

    <div class="clearfix"></div>

    <!--=================Header end=======================-->

    <!--=================Body Contain Start=======================-->

    <div class="wrapper">

      <div class="header">

        <?php include_once("dna_top.php"); ?>
        <style>
        	.dna-profile-hidden{
				display: none;
			}
		</style>
	<script type ="text/javascript" src="js/jquery-1.7.2.min.js"></script>
	<script type ="text/javascript" src="js/jquery.jdpicker.js"></script>
	<link rel="stylesheet" href="css/jdpicker.css" type="text/css" />
	<style>
		.date_clearer
		{
			display: none !important;
		}
	</style>
		<script>
			function displaySave(fromWhere)
			{
				if(fromWhere=="about")
				{
					$("#About_You_span").hide();
					$("#About_You").show();
				}
				else if(fromWhere=="quotes")
				{
					$("#Quotes_span").hide();
					$("#Quotes").show();
				}
				else if(fromWhere=="education")
				{
					$("#High_School_span").hide();
					$("#Intermediate_span").hide();
					$("#Graduate_span").hide();
					$("#Post_Graduate_span").hide();
					$("#Research_span").hide();
					$("#Certification_span").hide();
					$("#Certification").show();
					$("#Research").show();
					$("#Post_Graduate").show();
					$("#Graduate").show();
					$("#Intermediate").show();
					$("#High_School").show();
				}
				else if(fromWhere=="work")
				{
					$("#Company_Name_span").hide();
					$("#Designation_span").hide();
					$("#Time_Period_span").hide();
					$("#Profession_span").hide();
					$("#Profession").show()
					$("#Time_Period").show();
					$("#Designation").show();
					$("#Company_Name").show();
				}
				else if(fromWhere=="basic")
				{
					$("#Gender_span").hide();
					$("#DOB_span").hide();
					$("#Relationship_span").hide();
					$("#Language_span").hide();
					$("#Family_span").hide();
					$("#Religious_View_span").hide();
					$("#Political_View_span").hide();
					$("#Sports_span").hide();
					$("#Gender").show()
					$("#DOB").show();
					$("#Relationship").show();
					$("#Language").show();
					$("#Family").show()
					$("#Religious_View").show();
					$("#Political_View").show();
					$("#Sports").show();
				}
				else if(fromWhere=="contact")
				{
					$("#Email_ID_span").hide();
					$("#Mobile_Number_span").hide();
					$("#Phone_Number_span").hide();
					$("#Fax_Number_span").hide();
					$("#Address_span").hide();
					$("#Residence_span").hide();
					$("#Country_ID_span").hide();
					$("#Website_Link_span").hide();
					$("#Email_ID").show()
					$("#Mobile_Number").show();
					$("#Phone_Number").show();
					$("#Fax_Number").show();
					$("#Address").show()
					$("#Residence").show();
					$("#Country_ID").show();
					$("#Website_Link").show();
				}
				
				
				$("#"+fromWhere+"_edit_span").hide();
				$("#"+fromWhere+"_save_span").show();
				$("#"+fromWhere+"_cancel_span").show();
			}
			
			function hideSave(fromWhere)
			{
				if(fromWhere=="about")
				{
					$("#About_You").hide();
					$("#About_You_span").show();
				}
				else if(fromWhere=="quotes")
				{
					$("#Quotes").hide();
					$("#Quotes_span").show();
				}
				else if(fromWhere=="education")
				{
					$("#Certification").hide();
					$("#Research").hide();
					$("#Post_Graduate").hide();
					$("#Graduate").hide();
					$("#Intermediate").hide();
					$("#High_School").hide();
					
					$("#High_School_span").show();
					$("#Intermediate_span").show();
					$("#Graduate_span").show();
					$("#Post_Graduate_span").show();
					$("#Research_span").show();
					$("#Certification_span").show();
				}
				else if(fromWhere=="work")
				{
					$("#Profession").hide()
					$("#Time_Period").hide();
					$("#Designation").hide();
					$("#Company_Name").hide();
					
					$("#Company_Name_span").show();
					$("#Designation_span").show();
					$("#Time_Period_span").show();
					$("#Profession_span").show();
				}
				else if(fromWhere=="basic")
				{
					$("#Gender").hide()
					$("#DOB").hide();
					$("#Relationship").hide();
					$("#Language").hide();
					$("#Family").hide()
					$("#Religious_View").hide();
					$("#Political_View").hide();
					$("#Sports").hide();
					
					$("#Gender_span").show();
					$("#DOB_span").show();
					$("#Relationship_span").show();
					$("#Language_span").show();
					$("#Family_span").show();
					$("#Religious_View_span").show();
					$("#Political_View_span").show();
					$("#Sports_span").show();
				}
				else if(fromWhere=="contact")
				{
					$("#Email_ID").hide()
					$("#Mobile_Number").hide();
					$("#Phone_Number").hide();
					$("#Fax_Number").hide();
					$("#Address").hide()
					$("#Residence").hide();
					$("#Country_ID").hide();
					$("#Website_Link").hide();
					
					$("#Email_ID_span").show();
					$("#Mobile_Number_span").show();
					$("#Phone_Number_span").show();
					$("#Fax_Number_span").show();
					$("#Address_span").show();
					$("#Residence_span").show();
					$("#Country_ID_span").show();
					$("#Website_Link_span").show();
				}
				
				$("#"+fromWhere+"_save_span").hide();
				$("#"+fromWhere+"_cancel_span").hide();
				$("#"+fromWhere+"_edit_span").show();
			}
			
			function updateSpan(fromWhere)
			{
				if(fromWhere=="about")
				{
					$("#About_You_span").html($("#About_You").val());
				}
				else if(fromWhere=="quotes")
				{
					$("#Quotes_span").html($("#Quotes").val());
				}
				else if(fromWhere=="education")
				{
					$("#High_School_span").html($("#Certification").val());
					$("#Intermediate_span").html($("#Research").val());
					$("#Graduate_span").html($("#Post_Graduate").val());
					$("#Post_Graduate_span").html($("#Graduate").val());
					$("#Research_span").html($("#Intermediate").val());
					$("#Certification_span").html($("#High_School").val());
				}
				else if(fromWhere=="work")
				{
					$("#Company_Name_span").html($("#Profession").val());
					$("#Designation_span").html($("#Time_Period").val());
					$("#Time_Period_span").html($("#Designation").val());
					$("#Profession_span").html($("#Company_Name").val());
				}
				else if(fromWhere=="basic")
				{
					$("#Gender_span").html($("#Gender").val());
					$("#DOB_span").html($("#DOB").val());
					$("#Relationship_span").html($("#Relationship").val());
					$("#Language_span").html($("#Language").val());
					$("#Family_span").html($("#Family").val());
					$("#Religious_View_span").html($("#Religious_View").val());
					$("#Political_View_span").html($("#Political_View").val());
					$("#Sports_span").html($("#Sports").val());
				}
				else if(fromWhere=="contact")
				{
					$("#Email_ID_span").html($("#Email_ID").val());
					$("#Mobile_Number_span").html($("#Mobile_Number").val());
					$("#Phone_Number_span").html($("#Phone_Number").val());
					$("#Fax_Number_span").html($("#Fax_Number").val());
					$("#Address_span").html($("#Address").val());
					$("#Residence_span").html($("#Residence").val());
					$("#Country_ID_span").html($("#Country_ID").val());
					$("#Website_Link_span").html($("#Website_Link").val());
				}
				
				$("#"+fromWhere+"_save_span").hide();
				$("#"+fromWhere+"_cancel_span").hide();
				$("#"+fromWhere+"_edit_span").show();
			}
			
			function saveInfo(purpose)
			{
				$("#dna_purpose").val(purpose);
				formdata = false;
				if (window.FormData) {
					formdata = new FormData(document.getElementById("dna_profile_form"));
				}
				var xmlhttp;	
				if (window.XMLHttpRequest)
				{
					xmlhttp=new XMLHttpRequest();
				}
				else
				{
					xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
				}
				xmlhttp.onreadystatechange=function()
				{
					if (xmlhttp.readyState==4 && xmlhttp.status==200)
					{	
						//document.getElementById(purpose+"_image_loader_div").style.display="none";
						var res=xmlhttp.responseText;	
						resArr=res.split("|~|");
						if(resArr[0]=="SUCCESS")
						{
							updateSpan(purpose);
							hideSave(purpose);
						}
						else
						{
							alertify.alert(resArr[1]);
						}
					}
				}	
				xmlhttp.open("POST","ajax_dna_profile.php",true);
				xmlhttp.send(formdata);
			}
			
		</script>

		<div class="dna_form">
			<form id="dna_profile_form" name="dna_profile_form">
				<input type="hidden" name="dna_purpose" id="dna_purpose" value="" />
				<table width="100%" border="0" cellspacing="10px" cellpadding="10px" class="new" style="font-size:16px; font-weight:bold;border-collapse:separate !important;">
					<tr valign="top">
						<td valign="top"><span>About You</span></td>
						<td valign="top">
							<a href="javascript:void(0);" onclick="return displaySave('about');"><span class="dna_edit" id="about_edit_span" >Edit</span></a>
							<a href="javascript:void(0);" onclick="return hideSave('about');"><span class="dna_edit dna-profile-hidden" id="about_cancel_span" >Cancel</span></a>&nbsp;&nbsp;
							<a href="javascript:void(0);" onclick="return saveInfo('about');"><span class="dna_edit dna-profile-hidden" id="about_save_span" >Save</span></a>
						</td>
						<td valign="top"><span>Quotes</span></td>
						<td valign="top">
							<a href="javascript:void(0);" onclick="return displaySave('quotes');"><span class="dna_edit" id="quotes_edit_span" >Edit</span></a>
							<a href="javascript:void(0);" onclick="return hideSave('quotes');"><span class="dna_edit dna-profile-hidden" id="quotes_cancel_span" >Cancel</span></a>&nbsp;&nbsp;
							<a href="javascript:void(0);" onclick="return saveInfo('quotes');"><span class="dna_edit dna-profile-hidden" id="quotes_save_span" >Save</span></a>
						</td>
					</tr>
					<tr>
						<td valign="top" colspan="2">
							<input type="text" class="dna_big_txt dna-profile-hidden" id="About_You" name="About_You" value="<?php echo $dnauserinfo[0]["About_You"]; ?>"/>
							<span id="About_You_span"><?php if($dnauserinfo[0]["About_You"]!=""){ echo $dnauserinfo[0]["About_You"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top" colspan="2">
							<input type="text" class="dna_big_txt dna-profile-hidden" id="Quotes" name="Quotes" value="<?php echo $dnauserinfo[0]["Quotes"]; ?>"/>
							<span id="Quotes_span"><?php if($dnauserinfo[0]["Quotes"]!=""){ echo $dnauserinfo[0]["Quotes"];} else { echo "-"; } ?></span>
						</td>
					</tr>
	
					<tr valign="top">
						<td valign="top"><span>Education</span></td>
						<td valign="top">
					<?php
						if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
						{
					?>
							<a href="javascript:void(0);" onclick="return displaySave('education');"><span class="dna_edit" id="education_edit_span" >Edit</span></a>
							<a href="javascript:void(0);" onclick="return hideSave('education');"><span class="dna_edit dna-profile-hidden" id="education_cancel_span" >Cancel</span></a>&nbsp;&nbsp;
							<a href="javascript:void(0);" onclick="return saveInfo('education');"><span class="dna_edit dna-profile-hidden" id="education_save_span" >Save</span></a>
					<?php
						}
					?>
						</td>
						<td valign="top"><span>Work</span></td>
						<td valign="top">
					<?php
						if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
						{
					?>
							<a href="javascript:void(0);" onclick="return displaySave('work');"><span class="dna_edit" id="work_edit_span" >Edit</span></a>
							<a href="javascript:void(0);" onclick="return hideSave('work');"><span class="dna_edit dna-profile-hidden" id="work_cancel_span" >Cancel</span></a>&nbsp;&nbsp;
							<a href="javascript:void(0);" onclick="return saveInfo('work');"><span class="dna_edit dna-profile-hidden" id="work_save_span" >Save</span></a>
					<?php
						}
					?>
						</td>
					</tr>
	
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Schooling</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="High_School" name="High_School" value="<?php echo $dnauserinfo[0]["High_School"]; ?>" />
						<?php
							}
						?>
							<span id="High_School_span"><?php if($dnauserinfo[0]["High_School"]!=""){ echo $dnauserinfo[0]["High_School"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Company Name</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Company_Name" name="Company_Name" value="<?php echo $dnauserinfo[0]["Company_Name"]; ?>" />
						<?php
							}
						?>
							<span id="Company_Name_span"><?php if($dnauserinfo[0]["Company_Name"]!=""){ echo $dnauserinfo[0]["Company_Name"];} else { echo "-"; } ?></span>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">College 1</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="Intermediate" name="Intermediate" value="<?php echo $dnauserinfo[0]["Intermediate"]; ?>" />
						<?php
							}
						?>
							<span id="Intermediate_span"><?php if($dnauserinfo[0]["Intermediate"]!=""){ echo $dnauserinfo[0]["Intermediate"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Designation</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Designation" name="Designation" value="<?php echo $dnauserinfo[0]["Designation"]; ?>" />
						<?php
							}
						?>
							<span id="Designation_span"><?php if($dnauserinfo[0]["Designation"]!=""){ echo $dnauserinfo[0]["Designation"];} else { echo "-"; } ?></span>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">College 2</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="Graduate" name="Graduate" value="<?php echo $dnauserinfo[0]["Graduate"]; ?>" />
						<?php
							}
						?>
							<span id="Graduate_span"><?php if($dnauserinfo[0]["Graduate"]!=""){ echo $dnauserinfo[0]["Graduate"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Time Period</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Time_Period" name="Time_Period" value="<?php echo $dnauserinfo[0]["Time_Period"]; ?>" />
						<?php
							}
						?>
							<span id="Time_Period_span"><?php if($dnauserinfo[0]["Time_Period"]!=""){ echo $dnauserinfo[0]["Time_Period"];} else { echo "-"; } ?></span>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Post Graduation</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="Post_Graduate" name="Post_Graduate" value="<?php echo $dnauserinfo[0]["Post_Graduate"]; ?>" />
						<?php
							}
						?>
							<span id="Post_Graduate_span"><?php if($dnauserinfo[0]["Post_Graduate"]!=""){ echo $dnauserinfo[0]["Post_Graduate"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Profession</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Profession" name="Profession" value="<?php echo $dnauserinfo[0]["Profession"]; ?>" />
						<?php
							}
						?>
							<span id="Profession_span"><?php if($dnauserinfo[0]["Profession"]!=""){ echo $dnauserinfo[0]["Profession"];} else { echo "-"; } ?></span>
						</td>
					</tr>
	
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Research</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Research" name="Research" value="<?php echo $dnauserinfo[0]["Research"]; ?>" />
						<?php
							}
						?>
							<span id="Research_span"><?php if($dnauserinfo[0]["Research"]!=""){ echo $dnauserinfo[0]["Research"];} else { echo "-"; } ?></span>
						</td>
						<td colspan="2" valign="top">&nbsp;</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Certification</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Certification" name="Certification" value="<?php echo $dnauserinfo[0]["Certification"]; ?>" />
						<?php
							}
						?>
							<span id="Certification_span"><?php if($dnauserinfo[0]["Certification"]!=""){ echo $dnauserinfo[0]["Certification"];} else { echo "-"; } ?></span>
						</td>
						<td colspan="2" valign="top">&nbsp;</td>
					</tr>
	
					<tr valign="top">
						<td valign="top"><span>Basic Information</span></td>
						<td valign="top">
					<?php
						if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
						{
					?>
							<a href="javascript:void(0);" onclick="return displaySave('basic');"><span class="dna_edit" id="basic_edit_span" >Edit</span></a>
							<a href="javascript:void(0);" onclick="return hideSave('basic');"><span class="dna_edit dna-profile-hidden" id="basic_cancel_span" >Cancel</span></a>&nbsp;&nbsp;
							<a href="javascript:void(0);" onclick="return saveInfo('basic');"><span class="dna_edit dna-profile-hidden" id="basic_save_span" >Save</span></a>
					<?php
						}
					?>
						</td>
						<td valign="top"><span>Contact Information</span></td>
						<td valign="top">
					<?php
						if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
						{
					?>
							<a href="javascript:void(0);" onclick="return displaySave('contact');"><span class="dna_edit" id="contact_edit_span" >Edit</span></a>
							<a href="javascript:void(0);" onclick="return hideSave('contact');"><span class="dna_edit dna-profile-hidden" id="contact_cancel_span" >Cancel</span></a>&nbsp;&nbsp;
							<a href="javascript:void(0);" onclick="return saveInfo('contact');"><span class="dna_edit dna-profile-hidden" id="contact_save_span" >Save</span></a>
					<?php
						}
					?>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Gender</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="Gender" name="Gender" value="<?php echo $dnauserinfo[0]["Gender"]; ?>" />
						<?php
							}
						?>
							<span id="Gender_span"><?php if($dnauserinfo[0]["Gender"]!=""){ echo $dnauserinfo[0]["Gender"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">E-mail</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Email_ID" name="Email_ID" value="<?php echo $dnauserinfo[0]["Email_ID"]; ?>" />
						<?php
							}
						?>
							<span id="Email_ID_span"><?php if($dnauserinfo[0]["Email_ID"]!=""){ echo $dnauserinfo[0]["Email_ID"];} else { echo "-"; } ?></span>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Birthday</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" value="<?php if($dnauserinfo[0]["DOB"]!=""){ echo date("d/m/Y",$dnauserinfo[0]["DOB"]);} else { echo ""; } ?>" id="DOB" name="DOB" readonly="true" />
						<?php
							}
						?>
							<span id="DOB_span"><?php if($dnauserinfo[0]["DOB"]!=""){ echo date("d/m/Y",$dnauserinfo[0]["DOB"]);} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Mobile No.</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Mobile_Number" name="Mobile_Number" value="<?php echo $dnauserinfo[0]["Mobile_Number"]; ?>" />
						<?php
							}
						?>
							<span id="Mobile_Number_span"><?php if($dnauserinfo[0]["Mobile_Number"]!=""){ echo $dnauserinfo[0]["Mobile_Number"];} else { echo "-"; } ?></span>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Relationship</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="Relationship" name="Relationship" value="<?php echo $dnauserinfo[0]["Relationship"]; ?>" />
						<?php
							}
						?>
							<span id="Relationship_span"><?php if($dnauserinfo[0]["Relationship"]!=""){ echo $dnauserinfo[0]["Relationship"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Phone No.</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Phone_Number" name="Phone_Number" value="<?php echo $dnauserinfo[0]["Phone_Number"]; ?>" />
						<?php
							}
						?>
							<span id="Phone_Number_span"><?php if($dnauserinfo[0]["Phone_Number"]!=""){ echo $dnauserinfo[0]["Phone_Number"];} else { echo "-"; } ?></span>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Language</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="Language" name="Language" value="<?php echo $dnauserinfo[0]["Language"]; ?>" />
						<?php
							}
						?>
							<span id="Language_span"><?php if($dnauserinfo[0]["Language"]!=""){ echo $dnauserinfo[0]["Language"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Fax No.</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Fax_Number" name="Fax_Number" value="<?php echo $dnauserinfo[0]["Fax_Number"]; ?>" />
						<?php
							}
						?>
							<span id="Fax_Number_span"><?php if($dnauserinfo[0]["Fax_Number"]!="" && $dnauserinfo[0]["Fax_Number"]!=0){ echo $dnauserinfo[0]["Fax_Number"];} else { echo "-"; } ?></span>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Family</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="Family" name="Family" value="<?php echo $dnauserinfo[0]["Family"]; ?>" />
						<?php
							}
						?>
							<span id="Family_span"><?php if($dnauserinfo[0]["Family"]!=""){ echo $dnauserinfo[0]["Family"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Presently</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Address" name="Address" value="<?php echo $dnauserinfo[0]["Address"]; ?>" />
						<?php
							}
						?>
							<span id="Address_span"><?php if($dnauserinfo[0]["Address"]!=""){ echo $dnauserinfo[0]["Address"];} else { echo "-"; } ?></span>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Religious View</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="Religious_View" name="Religious_View" value="<?php echo $dnauserinfo[0]["Religious_View"]; ?>" />
						<?php
							}
						?>
							<span id="Religious_View_span"><?php if($dnauserinfo[0]["Religious_View"]!=""){ echo $dnauserinfo[0]["Religious_View"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Residence</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Residence" name="Residence" value="<?php echo $dnauserinfo[0]["Residence"]; ?>" />
						<?php
							}
						?>
							<span id="Residence_span"><?php if($dnauserinfo[0]["Residence"]!=""){ echo $dnauserinfo[0]["Residence"];} else { echo "-"; } ?></span>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Political View</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="Political_View" name="Political_View" value="<?php echo $dnauserinfo[0]["Political_View"]; ?>" />
						<?php
							}
						?>
							<span id="Political_View_span"><?php if($dnauserinfo[0]["Political_View"]!=""){ echo $dnauserinfo[0]["Political_View"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Country</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							
							<select style="width:299px;" class="dna_tbox dna-profile-hidden" id="Country_ID" name="Country_ID" >
								<option value="">Select Country</option>
							<?php
								for($countryCount=0;$countryCount<count($arrCountry); $countryCount++)
								{
							?>
								<option value="<?php echo $arrCountry[$countryCount]["Country_ID"]; ?>" <?php if($dnauserinfo[0]["Country_ID"]==$arrCountry[$countryCount]["Country_ID"]){ echo "selected"; } ?> ><?php echo $arrCountry[$countryCount]["Country_Name"]; ?></option>
							<?php		
								}
							?>	
							</select>
						<?php
							}
						?>
							<span id="Country_ID_span"><?php 
								if($dnauserinfo[0]["Country_ID"]!="" || $dnauserinfo[0]["Country_ID"] >0){ 
									$selquery="select Country_Name from af_countries  where Country_ID=:countryid";
                					$existsrecord= $pdodbobj->fetch_array($pdodbobj->query($selquery,array(":countryid"=>$dnauserinfo[0]["Country_ID"])));
                					
									echo $existsrecord[0]["Country_Name"];
								} else { echo "-"; } 
								?></span>
						</td>
					</tr>
					
					<tr valign="top">
						<td valign="top"><span class="blue_lable">Sports</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" id="Sports" name="Sports" value="<?php echo $dnauserinfo[0]["Sports"]; ?>" />
						<?php
							}
						?>
							<span id="Sports_span"><?php if($dnauserinfo[0]["Sports"]!=""){ echo $dnauserinfo[0]["Sports"];} else { echo "-"; } ?></span>
						</td>
						<td valign="top"><span class="blue_lable">Website</span></td>
						<td valign="top">
						<?php
							if($dnauserinfo[0]["User_ID"]==$_SESSION['Allyfolio_User_ID'])
							{
						?>
							<input type="text" class="dna_tbox dna-profile-hidden" style="width:299px;" id="Website_Link" name="Website_Link" value="<?php echo $dnauserinfo[0]["Website_Link"]; ?>" />
						<?php
							}
						?>
							<span id="Website_Link_span"><?php if($dnauserinfo[0]["Website_Link"]!=""){ ?><a href="<?php echo $dnauserinfo[0]["Website_Link"]; ?>" target="_blank"><?php echo $dnauserinfo[0]["Website_Link"]; ?></a><?php } else { echo "-"; } ?></span>
						</td>
					</tr>

			  </table>				
			</form>
		</div>

<div class="clearfix"></div>

       </div>  

</div>

    </div>

    <div class="clearfix"></div>

    <!--=================Body Contain end=======================-->

    </div>

 <?php
    require_once("includes/footer.php");
?>
<script>
	$(document).ready(function(){
		$('#DOB').jdPicker({
			date_format:"dd/mm/YYYY"
		});
	});
</script>